package com.mhc.suzuki.constant;

/**
 * @author Churry
 * @create 2017-09-29 18:29
 **/
public enum AuditProgressNodeTypeEnum {

    //征信节点
    CREDIT_NODE(0, "征信节点"),
    //申请节点
    APPLY_NODE(1, "申请节点"),

    TASK_NODE(2, "任务节点");

    private Integer code;
    private String name;

    AuditProgressNodeTypeEnum(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public Integer getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    public static String getNameByCode(Integer code) {
        for (AuditProgressNodeTypeEnum item : AuditProgressNodeTypeEnum.values()) {
            if (item.getCode().equals(code)) {
                return item.getName();
            }
        }
        return "";
    }

}
